//
//  AppFileSystem.swift
//  APP
//
//  Created by Rdxer on 2017/12/22.
//  Copyright © 2017年 Rdxer. All rights reserved.
//

import UIKit

/// 获取默认的路径
class AppFileSystem {
    /// 文档
    static let documentsDirectory: URL = {
        let urls = FileManager.default.urls(for: .documentDirectory, in: .userDomainMask)
        return urls[urls.endIndex - 1]
    }()
    /// 缓存
    static let cacheDirectory: URL = {
        let urls = FileManager.default.urls(for: .cachesDirectory, in: .userDomainMask)
        return urls[urls.endIndex - 1]
    }()
    /// doc 目录下 download 文件夹
    static let downloadDirectory: URL = {
        let directory: URL = AppFileSystem.documentsDirectory.appendingPathComponent("Download")
        return directory
    }()
}


